<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="utf-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
  <title>数据处理 - Even - A super concise theme for Hugo</title>
  <meta name="renderer" content="webkit" />
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1"/>

<meta http-equiv="Cache-Control" content="no-transform" />
<meta http-equiv="Cache-Control" content="no-siteapp" />

<meta name="theme-color" content="#f8f5ec" />
<meta name="msapplication-navbutton-color" content="#f8f5ec">
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="#f8f5ec">


<meta name="author" content="olOwOlo" /><meta name="description" content="sklearn相关 sklearn中决策树&amp;amp;随机森林 决策树以及随机森林二者对比的图像曲线 随机森林调整参数的图像曲线（网格搜索&amp;amp;" /><meta name="keywords" content="Hugo, theme, even" />






<meta name="generator" content="Hugo 0.83.1 with theme even" />


<link rel="canonical" href="https://xiongshou.github.io/post/%E6%95%B0%E6%8D%AE%E5%A4%84%E7%90%86/" />
<link rel="apple-touch-icon" sizes="180x180" href="/apple-touch-icon.png">
<link rel="icon" type="image/png" sizes="32x32" href="/favicon-32x32.png">
<link rel="icon" type="image/png" sizes="16x16" href="/favicon-16x16.png">
<link rel="manifest" href="/manifest.json">
<link rel="mask-icon" href="/safari-pinned-tab.svg" color="#5bbad5">



<link href="/sass/main.min.f92fd13721ddf72129410fd8250e73152cc6f2438082b6c0208dc24ee7c13fc4.css" rel="stylesheet">
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@fancyapps/fancybox@3.1.20/dist/jquery.fancybox.min.css" integrity="sha256-7TyXnr2YU040zfSP+rEcz29ggW4j56/ujTPwjMzyqFY=" crossorigin="anonymous">


<meta property="og:title" content="数据处理" />
<meta property="og:description" content="sklearn相关 sklearn中决策树&amp;随机森林 决策树以及随机森林二者对比的图像曲线 随机森林调整参数的图像曲线（网格搜索&amp;" />
<meta property="og:type" content="article" />
<meta property="og:url" content="https://xiongshou.github.io/post/%E6%95%B0%E6%8D%AE%E5%A4%84%E7%90%86/" /><meta property="article:section" content="post" />



<meta itemprop="name" content="数据处理">
<meta itemprop="description" content="sklearn相关 sklearn中决策树&amp;随机森林 决策树以及随机森林二者对比的图像曲线 随机森林调整参数的图像曲线（网格搜索&amp;">

<meta itemprop="wordCount" content="429">
<meta itemprop="keywords" content="数学建模," /><meta name="twitter:card" content="summary"/>
<meta name="twitter:title" content="数据处理"/>
<meta name="twitter:description" content="sklearn相关 sklearn中决策树&amp;随机森林 决策树以及随机森林二者对比的图像曲线 随机森林调整参数的图像曲线（网格搜索&amp;"/>

<!--[if lte IE 9]>
  <script src="https://cdnjs.cloudflare.com/ajax/libs/classlist/1.1.20170427/classList.min.js"></script>
<![endif]-->

<!--[if lt IE 9]>
  <script src="https://cdn.jsdelivr.net/npm/html5shiv@3.7.3/dist/html5shiv.min.js"></script>
  <script src="https://cdn.jsdelivr.net/npm/respond.js@1.4.2/dest/respond.min.js"></script>
<![endif]-->

</head>
<body>
  <div id="mobile-navbar" class="mobile-navbar">
  <div class="mobile-header-logo">
    <a href="/" class="logo">Even</a>
  </div>
  <div class="mobile-navbar-icon">
    <span></span>
    <span></span>
    <span></span>
  </div>
</div>
<nav id="mobile-menu" class="mobile-menu slideout-menu">
  <ul class="mobile-menu-list">
    <a href="/">
        <li class="mobile-menu-item">Home</li>
      </a><a href="/post/">
        <li class="mobile-menu-item">Archives</li>
      </a><a href="/tags/">
        <li class="mobile-menu-item">Tags</li>
      </a><a href="/categories/">
        <li class="mobile-menu-item">Categories</li>
      </a><a href="/about/">
        <li class="mobile-menu-item">About</li>
      </a>
  </ul>

  


</nav>

  <div class="container" id="mobile-panel">
    <header id="header" class="header">
        <div class="logo-wrapper">
  <a href="/" class="logo">Even</a>
</div>





<nav class="site-navbar">
  <ul id="menu" class="menu">
    <li class="menu-item">
        <a class="menu-item-link" href="/">Home</a>
      </li><li class="menu-item">
        <a class="menu-item-link" href="/post/">Archives</a>
      </li><li class="menu-item">
        <a class="menu-item-link" href="/tags/">Tags</a>
      </li><li class="menu-item">
        <a class="menu-item-link" href="/categories/">Categories</a>
      </li><li class="menu-item">
        <a class="menu-item-link" href="/about/">About</a>
      </li>
  </ul>
</nav>

    </header>

    <main id="main" class="main">
      <div class="content-wrapper">
        <div id="content" class="content">
          <article class="post">
    
    <header class="post-header">
      <h1 class="post-title">数据处理</h1>

      <div class="post-meta">
        <span class="post-time"> 0001-01-01 </span>
        <div class="post-category">
            <a href="/categories/%E6%95%B0%E5%AD%A6%E5%BB%BA%E6%A8%A1/"> 数学建模 </a>
            </div>
        
      </div>
    </header>

    <div class="post-toc" id="post-toc">
  <h2 class="post-toc-title">Contents</h2>
  <div class="post-toc-content always-active">
    <nav id="TableOfContents">
  <ul>
    <li><a href="#heading"></a></li>
    <li><a href="#sklearn相关">sklearn相关</a>
      <ul>
        <li><a href="#sklearn中决策树随机森林">sklearn中决策树&amp;随机森林</a></li>
        <li><a href="#sklearn中数据处理">sklearn中数据处理</a></li>
        <li><a href="#sklearn中的降维">sklearn中的降维</a></li>
        <li><a href="#sklearn支持向量机分类器">sklearn支持向量机分类器</a></li>
      </ul>
    </li>
    <li><a href="#xgboost预测梯度提升树">XGBoost预测（梯度提升树）</a></li>
    <li><a href="#降维操作">降维操作</a></li>
  </ul>
</nav>
  </div>
</div>
    <div class="post-content">
      <h1 id="heading"></h1>
<h1 id="sklearn相关">sklearn相关</h1>
<h2 id="sklearn中决策树随机森林">sklearn中决策树&amp;随机森林</h2>
<p>决策树以及随机森林二者对比的图像曲线</p>
<p>随机森林调整参数的图像曲线（网格搜索&amp;一次函数调整）</p>
<h2 id="sklearn中数据处理">sklearn中数据处理</h2>
<p>数据预处理</p>
<ul>
<li>数据无量纲化：数据归一化、标准化（正态分布）
<ul>
<li>选择标准化</li>
<li>异常值多的话，选择分位数来无量纲化</li>
</ul>
</li>
<li>缺失值处理
<ul>
<li>随机森林回归填补缺失值</li>
<li>中位数、众数、均值什么的</li>
<li>删除这个行、列</li>
</ul>
</li>
<li>处理分类形特征：编码、哑变量
<ul>
<li>编码：文字换数字</li>
</ul>
</li>
<li>二值化或者分段
<ul>
<li>根据阀值将数值二值化</li>
<li>连续性变量划分为段</li>
</ul>
</li>
</ul>
<h2 id="sklearn中的降维">sklearn中的降维</h2>
<ul>
<li>主成分分析</li>
<li>因子分析</li>
<li>独立成分分析</li>
<li>字典学习</li>
<li>高级矩阵分解</li>
</ul>
<h2 id="sklearn支持向量机分类器">sklearn支持向量机分类器</h2>
<h1 id="xgboost预测梯度提升树">XGBoost预测（梯度提升树）</h1>
<h1 id="降维操作">降维操作</h1>
<ol>
<li>首先通过K-means算法对所有数据进行二值化处理，然后使用关联规则 学习算法寻找导致某一个事情发生的因素。通过相关分析方法进一步简化了该因在这些步骤之后，我们 可以找到所有主要因素。然而，由于这些因素的数量众多，我们还需要使用PCA算法来 减少输出因素，以使预测模型更简单实用。</li>
</ol>

    </div>

    <div class="post-copyright">
  <p class="copyright-item">
    <span class="item-title">Author</span>
    <span class="item-content">olOwOlo</span>
  </p>
  <p class="copyright-item">
    <span class="item-title">LastMod</span>
    <span class="item-content">
        0001-01-01
        
    </span>
  </p>
  
  
</div>
<footer class="post-footer">
      <div class="post-tags">
          <a href="/tags/%E6%95%B0%E5%AD%A6%E5%BB%BA%E6%A8%A1/">数学建模</a>
          </div>
      <nav class="post-nav">
        <a class="prev" href="/post/%E5%9B%9E%E6%96%87%E5%AD%90%E4%B8%B2/">
            <i class="iconfont icon-left"></i>
            <span class="prev-text nav-default"></span>
            <span class="prev-text nav-mobile">Prev</span>
          </a>
        <a class="next" href="/post/%E8%BD%AF%E4%BB%B6%E6%B5%8B%E8%AF%95/">
            <span class="next-text nav-default">软件测试</span>
            <span class="next-text nav-mobile">Next</span>
            <i class="iconfont icon-right"></i>
          </a>
      </nav>
    </footer>
  </article>
        </div>
        

  

  

      </div>
    </main>

    <footer id="footer" class="footer">
      <div class="social-links">
      <a href="mailto:your@email.com" class="iconfont icon-email" title="email"></a>
      <a href="http://localhost:1313" class="iconfont icon-stack-overflow" title="stack-overflow"></a>
      <a href="http://localhost:1313" class="iconfont icon-twitter" title="twitter"></a>
      <a href="http://localhost:1313" class="iconfont icon-facebook" title="facebook"></a>
      <a href="http://localhost:1313" class="iconfont icon-linkedin" title="linkedin"></a>
      <a href="http://localhost:1313" class="iconfont icon-google" title="google"></a>
      <a href="http://localhost:1313" class="iconfont icon-github" title="github"></a>
      <a href="http://localhost:1313" class="iconfont icon-weibo" title="weibo"></a>
      <a href="http://localhost:1313" class="iconfont icon-zhihu" title="zhihu"></a>
      <a href="http://localhost:1313" class="iconfont icon-douban" title="douban"></a>
      <a href="http://localhost:1313" class="iconfont icon-pocket" title="pocket"></a>
      <a href="http://localhost:1313" class="iconfont icon-tumblr" title="tumblr"></a>
      <a href="http://localhost:1313" class="iconfont icon-instagram" title="instagram"></a>
      <a href="http://localhost:1313" class="iconfont icon-gitlab" title="gitlab"></a>
      <a href="http://localhost:1313" class="iconfont icon-bilibili" title="bilibili"></a>
  <a href="https://xiongshou.github.io/index.xml" type="application/rss+xml" class="iconfont icon-rss" title="rss"></a>
</div>

<div class="copyright">
  <span class="power-by">
    Powered by <a class="hexo-link" href="https://gohugo.io">Hugo</a>
  </span>
  <span class="division">|</span>
  <span class="theme-info">
    Theme - 
    <a class="theme-link" href="https://github.com/olOwOlo/hugo-theme-even">Even</a>
  </span>

  

  <span class="copyright-year">
    &copy; 
    2017 - 
    2021<span class="heart"><i class="iconfont icon-heart"></i></span><span>olOwOlo</span>
  </span>
</div>

    </footer>

    <div class="back-to-top" id="back-to-top">
      <i class="iconfont icon-up"></i>
    </div>
  </div>
  
  <script src="https://cdn.jsdelivr.net/npm/jquery@3.2.1/dist/jquery.min.js" integrity="sha256-hwg4gsxgFZhOsEEamdOYGBf13FyQuiTwlAQgxVSNgt4=" crossorigin="anonymous"></script>
  <script src="https://cdn.jsdelivr.net/npm/slideout@1.0.1/dist/slideout.min.js" integrity="sha256-t+zJ/g8/KXIJMjSVQdnibt4dlaDxc9zXr/9oNPeWqdg=" crossorigin="anonymous"></script>
  <script src="https://cdn.jsdelivr.net/npm/@fancyapps/fancybox@3.1.20/dist/jquery.fancybox.min.js" integrity="sha256-XVLffZaxoWfGUEbdzuLi7pwaUJv1cecsQJQqGLe7axY=" crossorigin="anonymous"></script>



<script type="text/javascript" src="/js/main.min.c99b103c33d1539acf3025e1913697534542c4a5aa5af0ccc20475ed2863603b.js"></script>








</body>
</html>
